package com.maychat.enums;

public enum UserStatus {
    ENABLED("启用"), DISABLED("禁用");
    private final String desc;

    UserStatus(String desc) {
        this.desc = desc;
    }

    public static UserStatus getByOrdinal(Integer ordinal) {
        UserStatus[] values = values();
        if (ordinal == null || ordinal < 0 || ordinal >= values.length) return null;
        return values[ordinal];
    }

    public String getDesc() {
        return desc;
    }
}
